package com.jiyun;

import org.springframework.amqp.core.Message;
import org.springframework.amqp.core.MessageListener;

public class MyMessageLinstener implements MessageListener {
    //当收到消息后，会调用这个方法，同时把消息传过来
    public void onMessage(Message message) {
        String msg = new String(message.getBody());
        System.out.println("1收到的："+msg);
    }
}
